package com.yeyks.common.annotation;


import com.yeyks.common.annotation.validator.PhoneValidator;

import javax.validation.Constraint;
import javax.validation.Payload;
import java.lang.annotation.ElementType;
import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;
import java.lang.annotation.Target;

/**
 * @author fuchangshuai
 * @date 2019/06/24 11:19
 */
@Target(ElementType.FIELD)
@Retention(RetentionPolicy.RUNTIME)
@Constraint(validatedBy = PhoneValidator.class)
public @interface PhoneCheck {
    String message() default "手机号输入不能为空";

    Class<?>[] groups() default {};

    Class<? extends Payload>[] payload() default {};
}
